package com.dao;

import com.bean.Repair;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

public interface RepairDAO  {

    /**
     * BeanListHandler将结果列表封装
     * @return
     * @throws SQLException
     */
     List<Repair> selectAll() throws SQLException ;
    /**
     * BeanHandler将单个列表封装
     * @param id
     * @return
     * @throws SQLException
     */

     Repair selectById(Integer id) throws SQLException ;

     List<Repair> selectByName(String ownerId) throws SQLException ;

     boolean deleteById(Integer id) throws SQLException ;

     boolean deleteAll(String[] idsArr) throws SQLException ;

     boolean insert(Repair r) throws SQLException;

     boolean update(Repair r) throws SQLException ;

    /**
     * ScalarHandler用来将单个Object类型封装
     * @return
     * @throws SQLException
     */

     Integer count() throws SQLException ;

     Integer countSearch(Map map) throws SQLException ;

     List<Repair> selectAllPagination(Integer offset, Integer limit) throws SQLException ;

     List<Repair> selectAllPaginationSearch(Integer offset, Integer limit, Map map) throws SQLException;

}
